391b6e
@@ -157,7 +157,7 @@
public abstract class ReplyManagerSupport extends ServiceSupport implements Repl
 
                     // restore correlation id in case the remote server messed with it
                     if (holder.getOriginalCorrelationId() != null) {
-                        if (exchange.getOut() != null) {
+                        if (exchange.hasOut()) {
                             exchange.getOut().setHeader(RabbitMQConstants.CORRELATIONID, holder.getOriginalCorrelationId());
                         } else {
                             exchange.getIn().setHeader(RabbitMQConstants.CORRELATIONID, holder.getOriginalCorrelationId());
